package com.yc.framework.utils;

import java.util.Collection;
import java.util.Map;

public  class DbIsEmpty {
    public static boolean IsEmpty(Object value){
        if (value == null)
            return true;
        if (value instanceof String) {
            if (((String) value).length() != 0) {
                return false;
            } else {
                return true;
            }
        }
        if (value instanceof Collection) {
            if (((Collection) value).size() != 0) {
                return false;
            } else {
                return true;
            }
        }
        return ((value instanceof Map) && (((Map) value).size() == 0));
    }
}
